cmake_minimum_required(VERSION 3.15)
project(cmp LANGUAGES C)

include(GNUInstallDirs)

add_library(cmp ${CMP_SRC_DIR}/cmp.c)
set_target_properties(cmp PROPERTIES
    WINDOWS_EXPORT_ALL_SYMBOLS ON
    PUBLIC_HEADER ${CMP_SRC_DIR}/cmp.h
)

install(TARGETS cmp
    ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
    LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
    RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
    PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}
)
